#pragma once
#include "Control.h"
#include "IEventListener.h"
class Button : public Control
{
public:
	void Create(vec2 pos, vec2 size, UINT32 id) override;
	bool OnInit() override;
	void Draw();
	void OnDestroy() override;
	void Resize(int w, int h) override;
	tstring GetClassName() override;

	void onMouseButtonDown(int button, int x, int y);
	void onMouseButtonUp(int button, int x, int y);
	void onMouseMove(int x, int y) override;

	vec3 clrBk;
	vec3 clrFore;
	vec3 clrHover;
	vec3 clrDown;
	string text;
	bool bHovered;
	bool bPressed;


	DEDCLAR_EH_MOUSE;

	//void onMouseLeave(int x, int y) override;

};


